<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<!-- Copyright 1997 The Open Group, All Rights Reserved -->
<title>uucp</title>
</head><body bgcolor=white>
<center>
<font size=2>
The Single UNIX &reg; Specification, Version 2<br>
Copyright &copy; 1997 The Open Group

</font></center><hr size=2 noshade>
<h4><a name = "tag_001_014_2619">&nbsp;</a>NAME</h4><blockquote>
uucp - system-to-system copy
</blockquote><h4><a name = "tag_001_014_2620">&nbsp;</a>SYNOPSIS</h4><blockquote>
<pre><code>

uucp <b>[</b>-cCdfjmr<b>][</b>-n <i>user</i><b>] </b><i>source-file</i>... <i>destination-file</i>
</code>
</pre>
</blockquote><h4><a name = "tag_001_014_2621">&nbsp;</a>DESCRIPTION</h4><blockquote>
The
<i>uucp</i>
utility
copies files named by the
<i>source-file</i>
arguments to the
<i>destination-file</i>
argument.
The files named can be on local or remote systems.
<p>
The
<i>uucp</i>
utility cannot guarantee support for all character encodings
in all circumstances.
For example,
transmission data may be restricted to 7-bits by the underlying
network, 8-bit data and filenames need not be portable to
non-internationalised systems, and so on.
Under these circumstances, it is recommended that only
characters defined in the
ISO/IEC&nbsp;646:1991 standard International Reference Version
(equivalent to ASCII) 7-bit range of
characters be used, and that only characters defined in the Portable
Filename Character Set be used for naming files.
</blockquote><h4><a name = "tag_001_014_2622">&nbsp;</a>OPTIONS</h4><blockquote>
The
<i>uucp</i>
utility supports the <b>XBD</b> specification, <a href="../xbd/utilconv.html#usg"><b>Utility Syntax Guidelines</b>&nbsp;</a> .
The following options are supported:
<dl compact>

<dt><b>-c</b>
<dd>Do not copy local file to the spool directory for transfer to the remote
machine (default).

<dt><b>-C</b>
<dd>Force the copy of local files to the spool directory for transfer.

<dt><b>-d</b>
<dd>Make all necessary directories for the file copy (default).

<dt><b>-f</b>
<dd>Do not make intermediate directories for the file copy.

<dt><b>-j</b>
<dd>Write the job identification string to standard output.
This job identification can be used by
<i><a href="uustat.html">uustat</a></i>
to obtain the status or terminate a job.

<dt><b>-m</b>
<dd>Send mail to the requester when the copy is
completed.

<dt><b>-n&nbsp;</b><i>user</i>
<dd>
Notify
<i>user</i>
on the remote system that a file was sent.

<dt><b>-r</b>
<dd>Do not start the file transfer; just queue the job.

</dl>
</blockquote><h4><a name = "tag_001_014_2623">&nbsp;</a>OPERANDS</h4><blockquote>
The following operands are supported:
<dl compact>

<dt><i>destination-file</i><dd>
<dt><i>source-file</i><dd>
A pathname of a file to be copied to, or from, respectively.
Either name can be a pathname on the local machine, or can
have the form:
<pre>
<code>
<i>system-name</i>!<i>pathname</i>
</code>
</pre>

where
<i>system-name</i>
is taken from a list of system names that
<i>uucp</i>
knows about; see
<i><a href="uuname.html">uuname</a></i>.
The destination
<i>system-name</i>
can also be a list of names such as:
<pre>
<code>
<i>system-name</i>!<i>system-name</i>!<i>...</i>!<i>system-name</i>!<i>pathname
</i></code>
</pre>

in which case, an attempt is made to send the file via the specified route
to the destination.
Care should be taken to ensure that intermediate nodes in the
route are willing to forward information.

The shell pattern matching notation characters
"?", "*" and
[...]
appearing in
<i>pathname</i>
will be expanded on the appropriate system.

Pathnames can be one of:
<ol>

<li>
An absolute pathname.

<li>
A pathname preceded by
<i>~user</i>
where
<i>user</i>
is a login name on the specified system
and is replaced by that user's login directory.
Note that if an invalid login is specified, the default is
to the public directory (called
<i>"PUBDIR"</i>;
the actual location of
<i>PUBDIR</i>
is implementation-dependent).

<li>
A pathname preceded by
<i>~/destination</i>
where
<i>destination</i>
is appended to
<i>PUBDIR.</i>
<dl><dt><b>Note:</b>
<dd>This destination will be treated as a filename unless
more than one file is being transferred by this request or
the destination is already a directory.
To ensure that it is a directory, follow the destination with a /.
For example,
<b>~/dan/</b>
as the destination will make the directory
<i>PUBDIR</i><b>/dan</b>
if it does not exist and put the requested files
in that directory.
</dl>
<p>
<li>
Anything else is prefixed by the current directory.
<p>
</ol>
<p>
If the result is an erroneous pathname for the remote system,
the copy will fail.
If the
<i>destination-file</i>
is a directory, the last part of the
<i>source-file</i>
name is used.
<p>
The read, write and execute permissions given by
<i>uucp</i>
are implementation-dependent.
<p>
</dl>
</blockquote><h4><a name = "tag_001_014_2624">&nbsp;</a>STDIN</h4><blockquote>
Not used.
</blockquote><h4><a name = "tag_001_014_2625">&nbsp;</a>INPUT FILES</h4><blockquote>
The files to be copied are regular files.
</blockquote><h4><a name = "tag_001_014_2626">&nbsp;</a>ENVIRONMENT VARIABLES</h4><blockquote>
The following environment variables affect the execution of
<i>uucp</i>:
<dl compact>

<dt><i>LANG</i><dd>Provide a default value for the internationalisation variables
that are unset or null.
If
<i>LANG</i>
is unset or null, the corresponding value from the
implementation-dependent default locale will be used.
If any of the internationalisation variables contains an invalid setting, the
utility will behave as if none of the variables had been defined.

<dt><i>LC_ALL</i><dd>
If set to a non-empty string value,
override the values of all the other internationalisation variables.

<dt><i>LC_COLLATE</i><dd>
Determine the locale for the
behaviour of ranges, equivalence classes
and multi-character collating elements
within bracketed filename patterns.

<dt><i>LC_CTYPE</i><dd>
Determine the
locale for the interpretation of sequences of bytes of text data as
characters (for example, single- as opposed to multi-byte characters
in arguments and input files)
and the behaviour of character classes
within bracketed filename patterns
(for example,
'[[:lower:]]*').

<dt><i>LC_MESSAGES</i><dd>
Determine the locale that should be used to affect
the format and contents of diagnostic
messages written to standard error,
and informative messages written to standard output.

<dt><i>LC_TIME</i><dd>
Determine the format of date and time strings output by
<i>uucp</i>.

<dt><i>NLSPATH</i><dd>
Determine the location of message catalogues
for the processing of
<i>LC_MESSAGES .
</i>
<dt><i>TZ</i><dd>Determine the timezone used with date and time strings.

</dl>
</blockquote><h4><a name = "tag_001_014_2627">&nbsp;</a>ASYNCHRONOUS EVENTS</h4><blockquote>
Default.
</blockquote><h4><a name = "tag_001_014_2628">&nbsp;</a>STDOUT</h4><blockquote>
Not used.
</blockquote><h4><a name = "tag_001_014_2629">&nbsp;</a>STDERR</h4><blockquote>
Used only for diagnostic messages.
</blockquote><h4><a name = "tag_001_014_2630">&nbsp;</a>OUTPUT FILES</h4><blockquote>
The output files (which may be on other systems)
are copies of the input files.
<p>
If the
<b>-m</b>
is used, mail files
will be modified.
</blockquote><h4><a name = "tag_001_014_2631">&nbsp;</a>EXTENDED DESCRIPTION</h4><blockquote>
None.
</blockquote><h4><a name = "tag_001_014_2632">&nbsp;</a>EXIT STATUS</h4><blockquote>
The following exit values are returned:
<dl compact>

<dt>0<dd>Successful completion.

<dt>&gt;0<dd>An error occurred.

</dl>
</blockquote><h4><a name = "tag_001_014_2633">&nbsp;</a>CONSEQUENCES OF ERRORS</h4><blockquote>
Default.
</blockquote><h4><a name = "tag_001_014_2634">&nbsp;</a>APPLICATION USAGE</h4><blockquote>
The domain of remotely accessible files can
(and for obvious security reasons usually should)
be severely restricted.
<p>
Note that the
"!"
character in addresses has to be escaped when using
<i>csh</i>
as a command interpreter because of its history substitution syntax.
For
<i>ksh</i>
and
<i><a href="sh.html">sh</a></i>
the escape is not necessary, but may be used.
<p>
Typical implementations of this utility require a communications
line configured to use the <b>XBD</b> specification, <a href="../xbd/termios.html"><b>General Terminal Interface</b>&nbsp;</a> ,
but other communications means may be used.
On systems where there are no available communications means
(either temporarily or permanently), this
utility will write an error message describing the problem
and exit with a non-zero exit status.
<br>
<p>
As noted above, shell metacharacters appearing in pathnames
are expanded on the appropriate system.
On an internationalised
system, this is done under the control of local settings of
<i>LC_COLLATE</i>
and
<i>LC_CTYPE .
</i>Thus, care should be taken when using
bracketed filename patterns, as collation and typing rules may vary
from one system to another.
Also be aware that certain types of
expression (that is, equivalence classes, character classes and collating
symbols) need not be supported on non-internationalised systems.
</blockquote><h4><a name = "tag_001_014_2635">&nbsp;</a>EXAMPLES</h4><blockquote>
None.
</blockquote><h4><a name = "tag_001_014_2636">&nbsp;</a>FUTURE DIRECTIONS</h4><blockquote>
None.
</blockquote><h4><a name = "tag_001_014_2637">&nbsp;</a>SEE ALSO</h4><blockquote>
<i><a href="mailx.html">mailx</a></i>,
<i><a href="uuencode.html">uuencode</a></i>,
<i><a href="uulog.html">uulog</a></i>,
<i><a href="uuname.html">uuname</a></i>,
<i><a href="uustat.html">uustat</a></i>,
<i><a href="uux.html">uux</a></i>.
</blockquote><hr size=2 noshade>
<center><font size=2>
UNIX &reg; is a registered Trademark of The Open Group.<br>
Copyright &copy; 1997 The Open Group
<br> [ <a href="../index.html">Main Index</a> | <a href="../xshix.html">XSH</a> | <a href="../xcuix.html">XCU</a> | <a href="../xbdix.html">XBD</a> | <a href="../cursesix.html">XCURSES</a> | <a href="../xnsix.html">XNS</a> ]

</font></center><hr size=2 noshade>
</body></html>
